<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <link REL="SHORTCUT ICON" HREF="<?php echo base_url() . APPPATH ?>themes/user/img/logo.png"/>
    
    <?php $this->load->view('_meta') ?>
    
    <title>Welcome iFree</title>
    <link href="<?php echo base_url() . APPPATH ?>themes/welcome/css/site.css" rel="stylesheet" type="text/css" />
    <script type="text/javascript" src="<?php echo base_url() . APPPATH ?>themes/admin/js/jquery/jquery.min.js"></script>	
    <script type="text/javascript" src="<?php echo base_url() . APPPATH ?>themes/welcome/js/jquery.lightbox_me.js"></script>	
    <script type="text/javascript" src="<?php echo base_url() . APPPATH ?>themes/welcome/js/jquery.complete-placeholder.min.js"></script> 
    <script type="text/javascript" src="<?php echo base_url() . APPPATH ?>themes/welcome/js/jquery.pngFix.pack.js"></script> 
    <script type="text/javascript">
      var base_url='<?php echo site_url(); ?>';
    </script>
    <link rel="stylesheet" href="<?php echo base_url() . APPPATH ?>themes/admin/css/validationEngine.jquery.css" type="text/css"/>
    <script src="<?php echo base_url() . APPPATH ?>themes/admin/js/jquery.validationEngine-en.js" type="text/javascript" charset="utf-8"></script>
    <script src="<?php echo base_url() . APPPATH ?>themes/admin/js/jquery.validationEngine.js" type="text/javascript" charset="utf-8"></script>

    <script type="text/javascript">  
      function placeholder(){
        $(document).placeholder({ 
          'set_class'            : true,
          'class_name'           : 'placeholder',
          'skip'                 : false,
          'ie_submit_swap'       : true, // If fallback validation isn't working in IE try setting to false.
          'ie_password_callback' : '' // Takes string to analyze and returns boolean. Workaround for if swap doesn't work.
        });
      }
      
      $(document).ready(function(){
        placeholder();
        $('#term_condition').click(function(e) {
          $('.formError').remove();
          $('#term_condition_popup').lightbox_me({
            centered: true,
            onClose : function(){
              $('.formError').remove();
            }
          });
          e.preventDefault();
        });
        $('#signin').click(function(e) {
          $('.formError').remove();
          $('#signin_popup').lightbox_me({
            centered: true,
            onLoad: function() { 
              $('#signin_popup').find('input:first').focus()
            },
            onClose : function(){
              $('.formError').remove();
            }
          });
          e.preventDefault();
        });
        $('#signup').click(function(e) {
          $('.formError').remove();
          $('#signup_popup').lightbox_me({
            centered: true,
            onClose : function(){
              $('.formError').remove();
            }
          });
          e.preventDefault();
        });
        $('#forgot_password').click(function(e) {
          $('.formError').remove();
          $('#forgot_password_popup').lightbox_me({
            centered: true,
            onClose : function(){
              $('.formError').remove();
            }
          });
          e.preventDefault();
        });
		<?php if(has_message()){ ?>
		alert('<?php echo flash_message() ?>');
		<?php } ?>
		<?php if(has_error()){ ?>
		alert('<?php echo flash_error() ?>');
		<?php } ?>
      });
      // This adds 'placeholder' to the items listed in the jQuery .support object. 
      jQuery(function() {
        jQuery.support.placeholder = false;
        test = document.createElement('input');
        if('placeholder' in test) jQuery.support.placeholder = true;
      });
      // This adds placeholder support to browsers that wouldn't otherwise support it. 
      $(function() {
        if(!$.support.placeholder) { 
          var active = document.activeElement;
          $(':text').focus(function () {
            if ($(this).attr('placeholder') != '' && $(this).val() == $(this).attr('placeholder')) {
              $(this).val('').removeClass('hasPlaceholder');
            }
          }).blur(function () {
            if ($(this).attr('placeholder') != '' && ($(this).val() == '' || $(this).val() == $(this).attr('placeholder'))) {
              $(this).val($(this).attr('placeholder')).addClass('hasPlaceholder');
            }
          });
          $(':text').blur();
          $(active).focus();
          $('form:eq(0)').submit(function () {
            $(':text.hasPlaceholder').val('');
          });
        }
      });
    </script>
  </head>
  <body>
    <div class="wrapper_screen">
      <div class="wrapper_main">
        <div class="head">
          <div class="logo cpos_1"></div>
          <div class="slogan cpos_2"></div>
          <div class="clearer"></div>
        </div>
        <div id="hoala1"><img src="<?php echo base_url() . APPPATH ?>themes/welcome/img/hoala1.png" width="425" height="544" /></div>
        <div class="box">
          <div id="stt"><img src="<?php echo base_url() . APPPATH ?>themes/welcome/img/stt.png" width="100" height="73" /></div>
          <div class="top_box"></div>
          <div class="rp_box">
            <div class="font30">Enter Your Email Address</div>
            <div class="font18 mg10">We'll send you Free things</div>
            <div class="search"> 
              <form method="post" action="">
                <input id="fulltextSearchText" class="input_search" type="text" value="" name="email"
                       <?php echo empty($error) ? 'placeholder="Your email"' : 'placeholder="' . $error . '" style="color:#FFD700"' ?>/>
                <input id="ctl00_Button1" class="button_search" type="submit" value="" 
                       style="background-color:Transparent;border-style:None;"/>
              </form>
            </div>
            <div class="mg10">By clicking Next I agree to the <a href="#" id="term_condition">Terms of Use</a></div>
          </div>
          <div class="bt_box">
            <div class="font18 center" style="width: 338px;margin-left: 138px">
              <a href="#" id="signin" class="signin_button"></a>
              <a class="signup_button" id="signup" href="#"></a>
              <a id="forgot_password" style="display:none" href="#">Sign up</a>
            </div>
          </div>

        </div>
        <div class="clearer"></div>
      </div>
    </div>
    <div class="clearer"></div>
    <?php $this->load->view('welcome/_term_condition') ?>
    <?php $this->load->view('welcome/_signup') ?>
    <?php $this->load->view('welcome/_signin') ?>
    <?php $this->load->view('welcome/_forgot_password') ?>
  </body>
</html>